import service from '@/utils/request'

// @Tags WorkflowLog
// @Summary 创建审批历史
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.WorkflowLog true "创建审批历史"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"创建成功"}"
// @Router /WorkflowLog/createWorkflowLog [post]
export const createWorkflowLog = (data) => {
  return service({
    url: '/WorkflowLog/createWorkflowLog',
    method: 'post',
    data
  })
}

// @Tags WorkflowLog
// @Summary 删除审批历史
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.WorkflowLog true "删除审批历史"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /WorkflowLog/deleteWorkflowLog [delete]
export const deleteWorkflowLog = (params) => {
  return service({
    url: '/WorkflowLog/deleteWorkflowLog',
    method: 'delete',
    params
  })
}

// @Tags WorkflowLog
// @Summary 批量删除审批历史
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body request.IdsReq true "批量删除审批历史"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"删除成功"}"
// @Router /WorkflowLog/deleteWorkflowLog [delete]
export const deleteWorkflowLogByIds = (params) => {
  return service({
    url: '/WorkflowLog/deleteWorkflowLogByIds',
    method: 'delete',
    params
  })
}

// @Tags WorkflowLog
// @Summary 更新审批历史
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data body model.WorkflowLog true "更新审批历史"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"更新成功"}"
// @Router /WorkflowLog/updateWorkflowLog [put]
export const updateWorkflowLog = (data) => {
  return service({
    url: '/WorkflowLog/updateWorkflowLog',
    method: 'put',
    data
  })
}

// @Tags WorkflowLog
// @Summary 用id查询审批历史
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query model.WorkflowLog true "用id查询审批历史"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"查询成功"}"
// @Router /WorkflowLog/findWorkflowLog [get]
export const findWorkflowLog = (params) => {
  return service({
    url: '/WorkflowLog/findWorkflowLog',
    method: 'get',
    params
  })
}

// @Tags WorkflowLog
// @Summary 分页获取审批历史列表
// @Security ApiKeyAuth
// @accept application/json
// @Produce application/json
// @Param data query request.PageInfo true "分页获取审批历史列表"
// @Success 200 {string} string "{"success":true,"data":{},"msg":"获取成功"}"
// @Router /WorkflowLog/getWorkflowLogList [get]
export const getWorkflowLogList = (params) => {
  return service({
    url: '/WorkflowLog/getWorkflowLogList',
    method: 'get',
    params
  })
}
